import Vue from 'vue'
import Router from 'vue-router'
import Index from 'page/index'
import NullTemp from 'components/nullTemp'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'Index',
      component: Index
    }, {
      // 登录
    	path: '/login',
      component: require('page/login/index')
    }, {
      // 注册
    	path: '/register',
      component: NullTemp,
      children: [{
      	path: '1',
      	component: require('page/register/step1')
      }, {
      	path: '2',
      	component: require('page/register/step2')
      }]
    }, {
      // 提现、收款记录
      path: '/order',
      component: NullTemp,
      children: [{
        path: 'collection',
        component: require('page/order/collection')
      }, {
        path: 'withdraw',
        component: require('page/order/withdraw')
      }]
    }, {
      // 修改密码
      path: '/password',
      component: NullTemp,
      children: [{
        path: 'list',
        component: require('page/password/list')
      }, {
        path: 'login',
        component: require('page/password/login')
      }, {
        path: 'withdraw',
        component: require('page/password/withdraw')
      }]
    }, {
      // 银行卡绑定
      path: '/bank',
      component: NullTemp,
      children: [{
        path: 'list',
        component: require('page/bank/list')
      }, {
        path: 'binding',
        component: require('page/bank/binding')
      }, {
        path: 'msg',
        component: require('page/bank/msg')
      }]
    }, {
      // 个人中心
      path: '/zone',
      component: NullTemp,
      children: [{
        path: 'index',
        component: require('page/zone/index')
      }, {
        path: 'certification',
        component: require('page/zone/certification')
      }]
    }, {
      // 提现
      path: '/withdraw',
      component: require('page/withdraw/index')
    }, {
      // 收款
      path: '/collection',
      component: require('page/collection/index')
    }
  ]
})
